<?php
/**
 * Function include template file from _shared directory
 * for current module
 */
function smarty_function_Box($param, &$smarty)
{
    $directory = '_shared';
    if(array_key_exists('selfview',$param))
    {
        $model = $smarty->getTemplateVars('__model');
        \Api\Config::Renew($model);
        $directory=\Api\Config::$param[\Api\ObjectLoader::C_CONTROLLER];        
    }
   return $smarty->fetch($directory.'/'.$param['name'].'.tpl');
   
}
?>